'use strict';

function median_to_letter(collection) {
  let temp=collection;  
  let average;
  function sortNumber(a,b)
    {
      return  a-b;
    }
    temp.sort(sortNumber);
    if(temp.length%2==0)
      {
        average=(temp[temp.length/2-1]+temp[temp.length/2+1-1])/2;
      }
    else 
      {
        average=temp[(temp.length+1)/2-1];
      }
    average=parseInt(average)+1;
    let collection1=String(average).split('');
    let list=['a','b','c','a','d','e','f','k','h','i','j','k']
    for(let i=0;i<collection1.lengthl;i++)
      {
        collection1[i]=parseInt(collection1[i]);
      }
    return (list[collection1[0]]+list[collection1[1]]);
}

module.exports = median_to_letter;
